package inter_home;

/**
 * @classname:Cricle
 * @description:
 * @author: Mr.Z
 * @date: 2020/12/3 21:09
 * @version: 0.1
 * @since:1.8
 */

public class Cricle extends Graph {
    public Cricle(double radius) {
        this.radius = radius;
    }

    public double getRadius() {
        return radius;
    }

    public void setRadius(double radius) {
        this.radius = radius;
    }

    private double radius;

    @Override
    public double area() {
        return Math.PI * Math.pow(radius, 2);
    }

    @Override
    public double peri() {
        return Math.PI * radius * 2;
    }
}
